diff options
| author | joonhoekim <26rote@gmail.com> | 2025-09-08 10:33:01 +0000 |
|---|---|---|
| committer | joonhoekim <26rote@gmail.com> | 2025-09-08 10:33:01 +0000 |
| commit | 10aa3d34bc599232af07d8a643c9938be14cb5bf (patch) | |
| tree | 9e9a94e89642e80024647de175de6f217daab682 /app/[lng]/evcp/(evcp)/menu-access-dept/_components/department-menu-access-manager.tsx | |
| parent | f93493f68c9f368e10f1c3379f1c1384068e3b14 (diff) | |
(김준회) 입찰 인터페이스 처리, 자재그룹명 매핑 수정, 자재그룹 뷰 수정, 부서별 도메인 할당시 동기화 처리, 도메인 부서 할당 다이얼로그 부서목록 스크롤 처리, 삼성중공업 사용자 global search 개선
Diffstat (limited to 'app/[lng]/evcp/(evcp)/menu-access-dept/_components/department-menu-access-manager.tsx')
| -rw-r--r-- | app/[lng]/evcp/(evcp)/menu-access-dept/_components/department-menu-access-manager.tsx | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/app/[lng]/evcp/(evcp)/menu-access-dept/_components/department-menu-access-manager.tsx b/app/[lng]/evcp/(evcp)/menu-access-dept/_components/department-menu-access-manager.tsx index bf43e7a9..c24770bf 100644 --- a/app/[lng]/evcp/(evcp)/menu-access-dept/_components/department-menu-access-manager.tsx +++ b/app/[lng]/evcp/(evcp)/menu-access-dept/_components/department-menu-access-manager.tsx @@ -15,6 +15,7 @@ import { import { assignDomainToDepartments, getDepartmentDomainAssignments, + autoAssignPendingUsersDomains, type UserDomain } from "@/lib/users/department-domain/service"; import { DOMAIN_OPTIONS } from "./domain-constants"; @@ -138,6 +139,17 @@ export function DepartmentMenuAccessManager({ } catch (error) { console.error("할당 정보 새로고침 실패:", error); } + + // users 테이블에 도메인 동기화 작업 진행 + try { + const syncResult = await autoAssignPendingUsersDomains(); + if (syncResult.success && syncResult.assignedCount > 0) { + toast.success(`사용자 도메인 동기화 완료: ${syncResult.assignedCount}명의 사용자가 자동 할당되었습니다.`); + } + } catch (error) { + console.error("사용자 도메인 동기화 실패:", error); + // 동기화 실패해도 메인 할당은 성공이므로 에러 토스트는 표시하지 않음 + } } else { toast.error(result.message); } |
